-----------------------------------------------------------------------------------------------------------------------
       log:  Z:\interactionmodels\addresults\legislativeparties_golder.log
  log type:  text
 opened on:  10 Jan 2007, 20:31:50

. *     ***************************************************************** *;
. *     ***************************************************************** *;
. *       File-Name:      legislativeparties_golder.do                    *;
. *       Date:           01/09/2007                                      *;
. *       Author:         MRG                                             *;
. *       Purpose:        Provide interaction figures for replication     *;
. *                       using Golder 2003 data.                         *;
. *       Input File:     golder1.dta                                     *;
. *       Output File:    legislativeparties_golder.log                   *;
. *       Data Output:    none                                            *;
. *       Previous file:                                                  *;
. *       Machine:                                                        *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. set mem 10m;
(10240k)

. use getdata\golder1.dta;

. *     ****************************************************************  *;
. *                       interaction figures                             *;
. *     ****************************************************************  *;
. regress legparties_nyu  proximity_nyu prescandidate_nyu prox_prescandidate_nyu logmag_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F(  4,    57) =    7.25
                                                       Prob > F      =  0.0001
                                                       R-squared     =  0.5934
                                                       Root MSE      =  1.2612

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
proximity_~u |  -1.698625    .651195    -2.61   0.012    -3.002621   -.3946299
prescandid~u |   1.100475   .3845845     2.86   0.006     .3303575    1.870592
prox_presc~u |  -.0073272   .5070473    -0.01   0.989    -1.022672    1.008017
  logmag_nyu |   .1047057   .0891881     1.17   0.245    -.0738905    .2833019
       _cons |   1.220594   .3490796     3.50   0.001     .5215746    1.919614
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (PRESCANDIDATE) = JH       *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>80;
(20 real changes made, 20 to missing)

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar covb1b3=V[1,3];

. scalar covb2b3=V[2,3];

. set more off;

. scalar list b1 b2 b3 varb1 varb2 varb3 covb1b3 covb2b3;
        b1 = -1.6986255
        b2 =  1.1004747
        b3 = -.00732717
     varb1 =  .42405497
     varb2 =  .14790526
     varb3 =  .25709694
   covb1b3 = -.25925988
   covb2b3 = -.16187968

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for proximity   *;
. *     ****************************************************************  *;
. gen conb=b1+b3*JH if _n<80;
(21 missing values generated)

. set more off;

. list conb in 1/20;

     +-----------+
     |      conb |
     |-----------|
  1. | -1.698625 |
  2. | -1.699358 |
  3. | -1.700091 |
  4. | -1.700824 |
  5. | -1.701556 |
     |-----------|
  6. | -1.702289 |
  7. | -1.703022 |
  8. | -1.703755 |
  9. | -1.704487 |
 10. |  -1.70522 |
     |-----------|
 11. | -1.705953 |
 12. | -1.706685 |
 13. | -1.707418 |
 14. | -1.708151 |
 15. | -1.708884 |
     |-----------|
 16. | -1.709616 |
 17. | -1.710349 |
 18. | -1.711082 |
 19. | -1.711814 |
 20. | -1.712547 |
     +-----------+

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse=sqrt(varb1+varb3*JH^2+2*covb1b3*JH)  if _n<80;
(21 missing values generated)

. set more off;

. *     ****************************************************************  *;
. *               Generate confidence intervals at the 95% level          *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. gen a=2.00*conse;
(21 missing values generated)

. gen top=conb+a;
(21 missing values generated)

. gen bottom=conb-a;
(21 missing values generated)

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of proximity on legislative parties            *;
. *       conditional on the number of presidential candidates            *;
. *     ****************************************************************  *;
. graph twoway   line conb JH, clwidth(medium) clcolor(blue) clcolor(black)
>         ||  line top  JH, clpattern(dash) clwidth(thin) clcolor(black)
>         ||  line bottom JH, clpattern(dash) clwidth(thin) clcolor(black)
>         ||  ,   
>             xlabel(0 1 2 3 4 5 6, labsize(2.5)) 
>             ylabel(-10 -5 0 5, labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             legend(col(1) order(1 2) label(1 "Estimated Causal Effect of Proximity") label(2 "95% Confidence Interval
> ") 
>                   label(3 " "))
>         yline(0, lcolor(black)) yline(-10 -5 5, lcolor(white))  
>             title("Estimated Causal Effect of Temporally-Proximate Presidential Elections", size(4))
>             subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " ", size(3))
>             xtitle(Effective Number of Presidential Candidates, size(3)  )
>         xsca(titlegap(2))
>         ysca(titlegap(2))
>             ytitle("Estimated Causal Effect of Proximity", size(3))
>         scheme(s2mono) graphregion(fcolor(white));

. *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\proximity1_leg.wmf, replace;
(file Z:\interactionmodels\addresults\proximity1_leg.wmf written in Windows Metafile format)

. drop JH conb cons a top bottom;

. *     ****************************************************************  *;
. *           Effect of fragmentation as concentration changes            *;
. *     ****************************************************************  *;
. regress legparties_nyu  fragmentation concentration frag_conc_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F(  3,    58) =    5.93
                                                       Prob > F      =  0.0013
                                                       R-squared     =  0.2238
                                                       Root MSE      =  1.7275

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
fragmentat~n |  -.3614426   .1304395    -2.77   0.007    -.6225457   -.1003395
concentrat~n |   .0220182   .4250082     0.05   0.959    -.8287281    .8727644
frag_conc_~u |   .2216223   .0963001     2.30   0.025     .0288568    .4143879
       _cons |   2.276211   .3014361     7.55   0.000     1.672821    2.879601
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (CONCENTRATION) = JH       *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>40;
(60 real changes made, 60 to missing)

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar covb1b3=V[1,3];

. scalar covb2b3=V[2,3];

. set more off;

. scalar list b1 b2 b3 varb1 varb2 varb3 covb1b3 covb2b3;
        b1 = -.36144259
        b2 =  .02201815
        b3 =  .22162234
     varb1 =  .01701447
     varb2 =  .18063195
     varb3 =   .0092737
   covb1b3 = -.00840702
   covb2b3 = -.03276451

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for             *;
. *       fragmentation                                                   *;
. *     ****************************************************************  *;
. gen conb=b1+b3*JH if _n<40;
(61 missing values generated)

. set more off;

. list conb in 1/20;

     +-----------+
     |      conb |
     |-----------|
  1. | -.3614426 |
  2. | -.3392803 |
  3. | -.3171181 |
  4. | -.2949559 |
  5. | -.2727937 |
     |-----------|
  6. | -.2506314 |
  7. | -.2284692 |
  8. | -.2063069 |
  9. | -.1841447 |
 10. | -.1619825 |
     |-----------|
 11. | -.1398202 |
 12. |  -.117658 |
 13. | -.0954958 |
 14. | -.0733335 |
 15. | -.0511713 |
     |-----------|
 16. | -.0290091 |
 17. | -.0068468 |
 18. |  .0153154 |
 19. |  .0374776 |
 20. |  .0596399 |
     +-----------+

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse=sqrt(varb1+varb3*JH^2+2*covb1b3*JH)  if _n<40;
(61 missing values generated)

. set more off;

. *     ****************************************************************  *;
. *               Generate confidence intervals at the 95% level          *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. gen a=2.00*conse;
(61 missing values generated)

. gen top=conb+a;
(61 missing values generated)

. gen bottom=conb-a;
(61 missing values generated)

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of fragmentation on legislative parties        *;
. *       conditional on concentration                                    *;
. *     ****************************************************************  *;
. graph twoway   line conb JH, clwidth(medium) clcolor(black)
>         ||  line top  JH, clpattern(dash) clwidth(thin) clcolor(black)
>         ||  line bottom JH, clpattern(dash) clwidth(thin) clcolor(black)
>         ||  ,   
>             xlabel(0 1 2 3 4, labsize(2.5)) 
>             ylabel( -1 0 1 , labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             legend(col(1) order(1 2) label(1 "Estimated Causal Effect of Fragmentation") label(2 "95% Confidence Inte
> rval") label(3 "Lower bound 95% C.I.") size(3))
>             yline(0, lcolor(black)) yline(-1  1 2, lcolor(white))
>             title(Estimated Causal Effect of Fragmentation, size(4))
>             subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " ", size(3))
>         xtitle("Concentration Index", size(3))
>         xsca(titlegap(2))
>         ysca(titlegap(2))
>             ytitle("Estimated Causal Effect of Fragmentation", size(3))
>             scheme(s2mono) graphregion(fcolor(white));

.             *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\fragmentation1_leg.wmf, replace;
(file Z:\interactionmodels\addresults\fragmentation1_leg.wmf written in Windows Metafile format)

. drop JH conb cons a top bottom;

. *     ****************************************************************  *;
. *       Institutional and sociological model - no interaction with      *;
. *       logmag yet.                                                     *;
. *     ****************************************************************  *;
. regress legparties_nyu  fragmentation concentration frag_conc_nyu logmag_nyu proximity_nyu 
> prescandidate_nyu prox_prescandidate_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F(  7,    54) =    9.59
                                                       Prob > F      =  0.0000
                                                       R-squared     =  0.6833
                                                       Root MSE      =  1.1435

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
fragmentat~n |  -.1864236   .1531799    -1.22   0.229    -.4935308    .1206835
concentrat~n |  -.4409183   .2639424    -1.67   0.101    -.9700909    .0882543
frag_conc_~u |   .1891142   .0930367     2.03   0.047     .0025869    .3756414
  logmag_nyu |   .2201648   .1387778     1.59   0.118     -.058068    .4983975
proximity_~u |  -1.237925   .4772906    -2.59   0.012    -2.194835   -.2810149
prescandid~u |   1.164438   .4516408     2.58   0.013     .2589529    2.069923
prox_presc~u |  -.3249101   .4229133    -0.77   0.446      -1.1728    .5229801
       _cons |    1.12016   .4666106     2.40   0.020     .1846621    2.055658
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (CONCENTRATION) = JH       *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>40;
(60 real changes made, 60 to missing)

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar covb1b3=V[1,3];

. scalar covb2b3=V[2,3];

. set more off;

. scalar list b1 b2 b3 varb1 varb2 varb3 covb1b3 covb2b3;
        b1 = -.18642363
        b2 = -.44091831
        b3 =  .18911417
     varb1 =  .02346408
     varb2 =  .06966557
     varb3 =  .00865582
   covb1b3 = -.01370147
   covb2b3 = -.02053238

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for             *;
. *       fragmentation                                                   *;
. *     ****************************************************************  *;
. gen conb=b1+b3*JH if _n<40;
(61 missing values generated)

. set more off;

. list conb in 1/20;

     +-----------+
     |      conb |
     |-----------|
  1. | -.1864236 |
  2. | -.1675122 |
  3. | -.1486008 |
  4. | -.1296894 |
  5. |  -.110778 |
     |-----------|
  6. | -.0918665 |
  7. | -.0729551 |
  8. | -.0540437 |
  9. | -.0351323 |
 10. | -.0162209 |
     |-----------|
 11. |  .0026905 |
 12. |   .021602 |
 13. |  .0405134 |
 14. |  .0594248 |
 15. |  .0783362 |
     |-----------|
 16. |  .0972476 |
 17. |   .116159 |
 18. |  .1350705 |
 19. |  .1539819 |
 20. |  .1728933 |
     +-----------+

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse=sqrt(varb1+varb3*JH^2+2*covb1b3*JH)  if _n<40;
(61 missing values generated)

. set more off;

. *     ****************************************************************  *;
. *               Generate confidence intervals at the 95% level          *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. gen a=2.00*conse;
(61 missing values generated)

. gen top=conb+a;
(61 missing values generated)

. gen bottom=conb-a;
(61 missing values generated)

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of fragmentation on legislative parties        *;
. *       conditional on concentration                                    *;
. *     ****************************************************************  *;
. graph twoway   line conb JH, clwidth(medium) 
>         ||  line top  JH, clpattern(dash) clwidth(thin) 
>         ||  line bottom JH, clpattern(dash) clwidth(thin) 
>         ||  ,   
>             xlabel(0 1 2 3 4, labsize(2.5)) 
>             ylabel( -1 0 1  , labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             legend(col(1) order(1 2) size(2.8) label(1 "Estimated Causal Effect of Fragmentation") label(2 "95% C.I."
> ) label(3 "95% C.I."))
>             yline(0, lcolor(black))  yline(-1 1 2, lcolor(white)) 
>             title(Estimated Causal Effect of Fragmentation, size(4))
>         subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " ", size(3))
>         xtitle("Concentration Index" " ", size(2.8))
>             ytitle(Estimated Causal Effect of Fragmentation, size(2.8))
>         xsca(titlegap(2))
>         ysca(titlegap(2))
>         scheme(s2mono) graphregion(fcolor(white));

. *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\fragmentation2_leg.wmf, replace;
(file Z:\interactionmodels\addresults\fragmentation2_leg.wmf written in Windows Metafile format)

. drop JH conb cons a top bottom;

. *     ****************************************************************  *;
. *       Institutional and sociological model - with interaction with    *;
. *       logmag now.                                                     *;
. *     ****************************************************************  *;
. regress legparties_nyu  fragmentation concentration logmag_nyu
>          frag_conc_nyu logmag_frag_nyu logmag_conc_nyu proximity_nyu 
>          prescandidate_nyu prox_prescandidate_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F(  9,    52) =   14.70
                                                       Prob > F      =  0.0000
                                                       R-squared     =  0.7218
                                                       Root MSE      =  1.0922

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
fragmentat~n |  -.5359209   .1666798    -3.22   0.002    -.8703883   -.2014535
concentrat~n |   -.316307   .2961178    -1.07   0.290    -.9105108    .2778968
  logmag_nyu |  -.2830118   .3615815    -0.78   0.437    -1.008578    .4425544
frag_conc_~u |   .2536725   .0761786     3.33   0.002      .100809    .4065359
logmag~g_nyu |   .1160214   .0515712     2.25   0.029     .0125363    .2195066
logmag_con~u |  -.0511496    .130571    -0.39   0.697    -.3131595    .2108603
proximity_~u |  -1.164922   .5515486    -2.11   0.040    -2.271685   -.0581585
prescandid~u |   1.099732   .3985507     2.76   0.008     .2999812    1.899482
prox_presc~u |  -.2269591   .3661171    -0.62   0.538    -.9616269    .5077087
       _cons |   1.876765   .4139788     4.53   0.000     1.046056    2.707474
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (LOGMAG) = JH              *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>30;
(70 real changes made, 70 to missing)

. generate str1 txt="*";

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar b4=b[1,4];

. scalar b5=b[1,5];

. scalar b6=b[1,6];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar varb4=V[4,4];

. scalar varb5=V[5,5];

. scalar varb6=V[6,6];

. scalar covb1b4=V[1,4];

. scalar covb1b5=V[1,5];

. scalar covb4b5=V[4,5];

. set more off;

. scalar list b1 b2 b3 b4 b5 b6 varb1 varb2 varb3 varb4 varb5 varb6 covb1b4 covb1b5 covb4b5;
        b1 = -.53592089
        b2 = -.31630702
        b3 = -.28301184
        b4 =  .25367246
        b5 =  .11602141
        b6 = -.05114958
     varb1 =  .02778214
     varb2 =  .08768574
     varb3 =  .13074115
     varb4 =  .00580317
     varb5 =  .00265959
     varb6 =  .01704879
   covb1b4 = -.00931577
   covb1b5 =  -.0053812
   covb4b5 =  .00013193

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for             *;
. *       fragmentation                                                   *;
. *     ****************************************************************  *;
. gen conb0=b1+b4*0+b5*JH if _n<30;
(71 missing values generated)

. gen conb1=b1+b4*1+b5*JH if _n<30;
(71 missing values generated)

. gen conb2=b1+b4*2+b5*JH if _n<30;
(71 missing values generated)

. gen conb3=b1+b4*3+b5*JH if _n<30;
(71 missing values generated)

. gen conb4=b1+b4*4+b5*JH if _n<30;
(71 missing values generated)

. set more off;

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse0=sqrt(varb1 + varb4*(0^2) + varb5*(JH^2)
>                 + 2*0*covb1b4 + 2*JH*covb1b5 + 2*0*JH*covb4b5)  if _n<30;
(71 missing values generated)

.                 gen conse1=sqrt(varb1 + varb4*(1^2) + varb5*(JH^2)
>                 + 2*1*covb1b4 + 2*JH*covb1b5 + 2*1*JH*covb4b5)  if _n<30;
(71 missing values generated)

.                 gen conse2=sqrt(varb1 + varb4*(2^2) + varb5*(JH^2)
>                 + 2*2*covb1b4 + 2*JH*covb1b5 + 2*2*JH*covb4b5)  if _n<30;
(71 missing values generated)

.                 gen conse3=sqrt(varb1 + varb4*(3^2) + varb5*(JH^2)
>                 + 2*3*covb1b4 + 2*JH*covb1b5 + 2*3*JH*covb4b5)  if _n<30;
(71 missing values generated)

.                 gen conse4=sqrt(varb1 + varb4*(4^2) + varb5*(JH^2)
>                 + 2*4*covb1b4 + 2*JH*covb1b5 + 2*4*JH*covb4b5)  if _n<30;
(71 missing values generated)

.                 set more off;

. *     ****************************************************************  *;
. *                           Create t statistics                         *;
. *     ****************************************************************  *;
. gen t0=conb0/conse0;
(71 missing values generated)

. gen t1=conb1/conse1;
(71 missing values generated)

. gen t2=conb2/conse2;
(71 missing values generated)

. gen t3=conb3/conse3;
(71 missing values generated)

. gen t4=conb4/conse4;
(71 missing values generated)

. *     ****************************************************************  *;
. *       Generate a variable equal to conditional betas                  *;
. *     ****************************************************************  *;
. gen consb0=conb0;
(71 missing values generated)

. gen consb1=conb1;
(71 missing values generated)

. gen consb2=conb2;
(71 missing values generated)

. gen consb3=conb3;
(71 missing values generated)

. gen consb4=conb4;
(71 missing values generated)

. *     ****************************************************************  *;
. *       Replace consb_ = missing if t score not bigger than cutoff      *;
. *     ****************************************************************  *;
. replace consb0 = . if abs(t0)<2.01;
(5 real changes made, 5 to missing)

. replace consb1 = . if abs(t1)<2.01;
(19 real changes made, 19 to missing)

. replace consb2 = . if abs(t2)<2.01;
(15 real changes made, 15 to missing)

. replace consb3 = . if abs(t3)<2.01;
(5 real changes made, 5 to missing)

. replace consb4 = . if abs(t4)<2.01;
(0 real changes made)

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of fragmentation on legislative parties        *;
. *       conditional on logmag                                           *;
. *     ****************************************************************  *;
. graph twoway   line conb0 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb0 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb1 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb1 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb2 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb2 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb3 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb3 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)        
>         ||  line conb4 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb4 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  ,   
>             ysize(6)
>             xsize(8)
>             xlabel(0 1 2 3 , labsize(2.5)) 
>             ylabel(-1 0 1, labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             legend(off)
>             yline(0, lcolor(black)) yline(-1 1 2, lcolor(white))  
>             title(Estimated Causal Effect of Fragmentation, size(4))
>             xtitle(Logged Average District Magnitude, size(3))
>             ytitle(Estimated Causal Effect of Fragmentation, size(3))
>         xsca(titlegap(2))
>         ysca(titlegap(3))
>         text(0.85 3.28 "Concentration Index=4", justification(left) size(2.5))
>         text(0.6 3.28 "Concentration Index=3", justification(left) size(2.5))
>         text(0.33 3.28 "Concentration Index=2", justification(left) size(2.5))
>         text(0.08 3.28 "Concentration Index=1", justification(left) size(2.5))
>         text(-0.18 3.28 "Concentration Index=0", justification(left) size(2.5))
>         text(1 1.1 "* indicates significance at the 95% level", justification(left) size(2.5))
>         subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " ", size(3))
>         scheme(s2mono) graphregion(fcolor(white))
>         graphregion(margin(r=24));

.             drop JH conb0 conb1 conb2 conb3 conb4 consb0 consb1 consb2 consb3 consb4 conse0 conse1 conse2 conse3 cons
> e4 t0 t1 t2 t3 t4 txt;

. *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\fragmentation3_leg.wmf, replace;
(note: file addresults\fragmentation3_leg.wmf not found)
(file Z:\interactionmodels\addresults\fragmentation3_leg.wmf written in Windows Metafile format)

. *     ****************************************************************  *;
. *       Institutional and sociological model - with interaction with    *;
. *       logmag and now with triple interaction included.                *;
. *     ****************************************************************  *;
. regress legparties_nyu  fragmentation concentration logmag_nyu 
>         frag_conc_nyu logmag_frag_nyu logmag_conc_nyu 
>         logmag_frag_conc_nyu proximity_nyu prescandidate_nyu 
>         prox_prescandidate_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F( 10,    51) =   22.09
                                                       Prob > F      =  0.0000
                                                       R-squared     =  0.7478
                                                       Root MSE      =  1.0501

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
fragmentat~n |  -.2248163   .1265585    -1.78   0.082    -.4788932    .0292605
concentrat~n |   .2562715   .3113018     0.82   0.414     -.368693     .881236
  logmag_nyu |   .2313167   .3456314     0.67   0.506    -.4625673    .9252008
frag_conc_~u |   .0667588   .0751343     0.89   0.378    -.0840795    .2175971
logmag~g_nyu |  -.0417166   .0576189    -0.72   0.472    -.1573914    .0739582
logmag_con~u |  -.4795553   .1891182    -2.54   0.014    -.8592259   -.0998847
logmag_fra.. |   .1191454   .0361963     3.29   0.002     .0464784    .1918125
proximity_~u |  -1.052137   .4961196    -2.12   0.039    -2.048138   -.0561352
prescandid~u |   1.063056    .387872     2.74   0.008     .2843704    1.841742
prox_presc~u |  -.2099409   .3445643    -0.61   0.545    -.9016826    .4818008
       _cons |   1.089721   .2999469     3.63   0.001     .4875519    1.691889
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (LOGMAG) = JH              *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>30;
(70 real changes made, 70 to missing)

. generate str1 txt="*";

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar b4=b[1,4];

. scalar b5=b[1,5];

. scalar b6=b[1,6];

. scalar b7=b[1,7];

. scalar b8=b[1,8];

. scalar b9=b[1,9];

. scalar b10=b[1,10];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar varb4=V[4,4];

. scalar varb5=V[5,5];

. scalar varb6=V[6,6];

. scalar varb7=V[7,7];

. scalar varb8=V[8,8];

. scalar varb9=V[9,9];

. scalar varb10=V[10,10];

. scalar covb1b4=V[1,4];

. scalar covb1b5=V[1,5];

. scalar covb1b7=V[1,7];

. scalar covb3b5=V[3,5];

. scalar covb3b6=V[3,6];

. scalar covb3b7=V[3,7];

. scalar covb5b6=V[5,6];

. scalar covb6b7=V[6,7];

. scalar covb4b5=V[4,5];

. scalar covb4b7=V[4,7];

. scalar covb5b7=V[5,7];

. set more off;

. scalar list b1 b2 b3 b4 b5 b6 b7 varb1 varb2 varb3 varb4 varb5 varb6 varb7 
>             covb1b4 covb1b5 covb1b7 covb4b5 covb4b7 covb5b7;
        b1 = -.22481632
        b2 =  .25627147
        b3 =  .23131673
        b4 =   .0667588
        b5 = -.04171663
        b6 = -.47955528
        b7 =  .11914543
     varb1 =  .01601706
     varb2 =  .09690883
     varb3 =   .1194611
     varb4 =  .00564516
     varb5 =  .00331994
     varb6 =  .03576569
     varb7 =  .00131017
   covb1b4 = -.00609377
   covb1b5 =  -.0044545
   covb1b7 =   .0018696
   covb4b5 =  .00074096
   covb4b7 = -.00166423
   covb5b7 =  -.0013198

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for             *;
. *       fragmentation                                                   *;
. *     ****************************************************************  *;
. gen conb0=b1+b4*0+b5*JH+b7*(0*JH) if _n<30;
(71 missing values generated)

. gen conb1=b1+b4*1+b5*JH+b7*(1*JH) if _n<30;
(71 missing values generated)

. gen conb2=b1+b4*2+b5*JH+b7*(2*JH) if _n<30;
(71 missing values generated)

. gen conb3=b1+b4*3+b5*JH+b7*(3*JH) if _n<30;
(71 missing values generated)

. gen conb4=b1+b4*4+b5*JH+b7*(4*JH) if _n<30;
(71 missing values generated)

. set more off;

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse0=sqrt(varb1
>                 + varb4*0 + varb5*JH^2 + varb7*JH^2*(0^2)
>                 + 2*0*covb1b4 + 2*JH*covb1b5 + 2*0*JH*covb1b7+2*0*JH*covb4b5
>                 + 2*(0^2)*JH*covb4b7 + 2*0*(JH^2)*covb5b7)  if _n<30;
(71 missing values generated)

.                 gen conse1=sqrt(varb1
>                 + varb4*1 + varb5*JH^2 + varb7*JH^2*(1^2)
>                 + 2*1*covb1b4 + 2*JH*covb1b5 + 2*1*JH*covb1b7+2*1*JH*covb4b5
>                 + 2*(1^2)*JH*covb4b7 + 2*1*(JH^2)*covb5b7)  if _n<30;
(71 missing values generated)

.                 gen conse2=sqrt(varb1
>                 + varb4*4 + varb5*JH^2 + varb7*JH^2*(2^2)
>                 + 2*2*covb1b4 + 2*JH*covb1b5 + 2*2*JH*covb1b7+2*2*JH*covb4b5
>                 + 2*(2^2)*JH*covb4b7 + 2*2*(JH^2)*covb5b7)  if _n<30;
(71 missing values generated)

.                 gen conse3=sqrt(varb1
>                 + varb4*9 + varb5*JH^2 + varb7*JH^2*(3^2)
>                 + 2*3*covb1b4 + 2*JH*covb1b5 + 2*3*JH*covb1b7+2*3*JH*covb4b5
>                 + 2*(3^2)*JH*covb4b7 + 2*3*(JH^2)*covb5b7)  if _n<30;
(71 missing values generated)

.                 gen conse4=sqrt(varb1
>                 + varb4*16 + varb5*JH^2 + varb7*JH^2*(4^2)
>                 + 2*4*covb1b4 + 2*JH*covb1b5 + 2*4*JH*covb1b7+2*4*JH*covb4b5
>                 + 2*(4^2)*JH*covb4b7 + 2*4*(JH^2)*covb5b7)  if _n<30;
(71 missing values generated)

.                 set more off;

. *     ****************************************************************  *;
. *                           Create t statistics                         *;
. *     ****************************************************************  *;
. gen t0=conb0/conse0;
(71 missing values generated)

. gen t1=conb1/conse1;
(71 missing values generated)

. gen t2=conb2/conse2;
(71 missing values generated)

. gen t3=conb3/conse3;
(71 missing values generated)

. gen t4=conb4/conse4;
(71 missing values generated)

. *     ****************************************************************  *;
. *       Generate a variable equal to conditional betas                  *;
. *     ****************************************************************  *;
. gen consb0=conb0;
(71 missing values generated)

. gen consb1=conb1;
(71 missing values generated)

. gen consb2=conb2;
(71 missing values generated)

. gen consb3=conb3;
(71 missing values generated)

. gen consb4=conb4;
(71 missing values generated)

. *     ****************************************************************  *;
. *       Replace consb_ = missing if t score not bigger than cutoff      *;
. *     ****************************************************************  *;
. replace consb0 = . if abs(t0)<2.01;
(3 real changes made, 3 to missing)

. replace consb1 = . if abs(t1)<2.01;
(29 real changes made, 29 to missing)

. replace consb2 = . if abs(t2)<2.01;
(12 real changes made, 12 to missing)

. replace consb3 = . if abs(t3)<2.01;
(9 real changes made, 9 to missing)

. replace consb4 = . if abs(t4)<2.01;
(8 real changes made, 8 to missing)

. set textsize 100;

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of fragmentation on legislative parties        *;
. *       conditional on logmag                                           *;
. *     ****************************************************************  *;
. graph twoway   line conb0 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb0 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb1 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb1 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb2 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb2 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb3 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb3 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)        
>         ||  line conb4 JH , clpattern(solid) clwidth(thin)
>         ||  scatter consb4 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  ,   
>             ysize(6)
>             xsize(8)
>             xlabel(0 1 2 3, labsize(2.5)) 
>             ylabel(-0.5 0 0.5 1 1.5 , labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             legend(off)
>             yline(0, lcolor(black)) yline(-0.5  0.5 1 1.5, lcolor(white)) 
>             title(Estimated Causal Effect of Fragmentation, size(4))
>             xtitle(Logged Average District Magnitude, size(3))
>             ytitle(Estimated Causal Effect of Fragmentation, size(3))
>         xsca(titlegap(2)) ysca(titlegap(4))
>         text(1.28 3.3 "Concentration Index=4", justification(left) size(2.5))
>         text(0.9 3.3 "Concentration Index=3", justification(left) size(2.5))
>         text(0.49 3.3 "Concentration Index=2", justification(left) size(2.5))
>         text(0.08 3.3 "Concentration Index=1", justification(left) size(2.5))
>         text(-0.33 3.3 "Concentration Index=0", justification(left) size(2.5))
>         text(1.5 1 "* indicates significance at the 95% level", justification(left) size(2.5))
>         subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " " " ", size(3))
>         scheme(s2mono) graphregion(fcolor(white))
>         graphregion(margin(r=28));

.        set textsize 100;

. *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\fragmentation4_leg.wmf, replace;
(note: file addresults\fragmentation4_leg.wmf not found)
(file Z:\interactionmodels\addresults\fragmentation4_leg.wmf written in Windows Metafile format)

. *     ****************************************************************  *;
. *       Proximity                                                       *;
. *     ****************************************************************  *;
. drop JH conb0 conb1 conb2 conb3 conb4 consb0 consb1 consb2 consb3 consb4 conse0 conse1 conse2 conse3 conse4 t0 t1 t2 
> t3 t4 txt;

. regress legparties_nyu  fragmentation concentration logmag_nyu frag_conc_nyu logmag_frag_nyu  
> logmag_conc_nyu logmag_frag_conc_nyu proximity_nyu prescandidate_nyu prox_prescandidate_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F( 10,    51) =   22.09
                                                       Prob > F      =  0.0000
                                                       R-squared     =  0.7478
                                                       Root MSE      =  1.0501

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
fragmentat~n |  -.2248163   .1265585    -1.78   0.082    -.4788932    .0292605
concentrat~n |   .2562715   .3113018     0.82   0.414     -.368693     .881236
  logmag_nyu |   .2313167   .3456314     0.67   0.506    -.4625673    .9252008
frag_conc_~u |   .0667588   .0751343     0.89   0.378    -.0840795    .2175971
logmag~g_nyu |  -.0417166   .0576189    -0.72   0.472    -.1573914    .0739582
logmag_con~u |  -.4795553   .1891182    -2.54   0.014    -.8592259   -.0998847
logmag_fra.. |   .1191454   .0361963     3.29   0.002     .0464784    .1918125
proximity_~u |  -1.052137   .4961196    -2.12   0.039    -2.048138   -.0561352
prescandid~u |   1.063056    .387872     2.74   0.008     .2843704    1.841742
prox_presc~u |  -.2099409   .3445643    -0.61   0.545    -.9016826    .4818008
       _cons |   1.089721   .2999469     3.63   0.001     .4875519    1.691889
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (PRESCANDIDATE) = JH       *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>80;
(20 real changes made, 20 to missing)

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar b4=b[1,4];

. scalar b5=b[1,5];

. scalar b6=b[1,6];

. scalar b7=b[1,7];

. scalar b8=b[1,8];

. scalar b9=b[1,9];

. scalar b10=b[1,10];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar varb4=V[4,4];

. scalar varb5=V[5,5];

. scalar varb6=V[6,6];

. scalar varb7=V[7,7];

. scalar varb8=V[8,8];

. scalar varb9=V[9,9];

. scalar varb10=V[10,10];

. scalar covb1b4=V[1,4];

. scalar covb1b5=V[1,5];

. scalar covb1b7=V[1,7];

. scalar covb3b5=V[3,5];

. scalar covb3b6=V[3,6];

. scalar covb3b7=V[3,7];

. scalar covb5b6=V[5,6];

. scalar covb6b7=V[6,7];

. scalar covb4b5=V[4,5];

. scalar covb4b7=V[4,7];

. scalar covb5b7=V[5,7];

. scalar covb8b10=V[8,10];

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for proximity   *;
. *     ****************************************************************  *;
. gen conb=b8+b10*JH if _n<80;
(21 missing values generated)

. set more off;

. list conb in 1/20;

     +-----------+
     |      conb |
     |-----------|
  1. | -1.052137 |
  2. | -1.073131 |
  3. | -1.094125 |
  4. | -1.115119 |
  5. | -1.136113 |
     |-----------|
  6. | -1.157107 |
  7. | -1.178101 |
  8. | -1.199095 |
  9. |  -1.22009 |
 10. | -1.241084 |
     |-----------|
 11. | -1.262078 |
 12. | -1.283072 |
 13. | -1.304066 |
 14. |  -1.32506 |
 15. | -1.346054 |
     |-----------|
 16. | -1.367048 |
 17. | -1.388042 |
 18. | -1.409036 |
 19. |  -1.43003 |
 20. | -1.451025 |
     +-----------+

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse=sqrt(varb8+varb10*JH^2+2*covb8b10*JH)  if _n<80;
(21 missing values generated)

. set more off;

. *     ****************************************************************  *;
. *               Generate confidence intervals at the 95% level          *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. gen a=2.01*conse;
(21 missing values generated)

. gen top=conb+a;
(21 missing values generated)

. gen bottom=conb-a;
(21 missing values generated)

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of proximity on legislative parties conditional*;
. *       on the number of presidential candidates                        *;
. *     ****************************************************************  *;
. graph twoway   line conb JH, clwidth(medium) clcolor(blue) clcolor(black)
>         ||  line top  JH, clpattern(dash) clwidth(thin) clcolor(black)
>         ||  line bottom JH, clpattern(dash) clwidth(thin) clcolor(black)
>         ||  ,   
>             xlabel(0 1 2 3 4 5 6 7 8, labsize(2.5)) 
>             ylabel(-10 -5 0 5  , labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             legend(col(1) order(1 2) label(1 "Estimated Causal Effect of Proximity") label(2 "95% Confidence Interval
> ") 
>                   label(3 " "))
>         yline(0, lcolor(black)) yline(-5 5, lcolor(white))  
>             title("Estimated Causal Effect of Temporally-Proximate Presidential Elections", size(4))
>             subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " ", size(3))
>             xtitle(Effective Number of Presidential Candidates, size(3)  )
>         xsca(titlegap(2))
>         ysca(titlegap(2))
>             ytitle("Estimated Causal Effect of Proximity", size(3))
>         scheme(s2mono) graphregion(fcolor(white));

. *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\proximity2_leg.wmf, replace;
(note: file addresults\proximity2_leg.wmf not found)
(file Z:\interactionmodels\addresults\proximity2_leg.wmf written in Windows Metafile format)

. drop JH conb top bottom a;

. *     ****************************************************************  *;
. *           Now calculate the marginal causal effect of logmag as       *;
. *           fragmentation changes                                       *;
. *     ****************************************************************  *;
. regress legparties_nyu  fragmentation concentration logmag_nyu frag_conc_nyu logmag_frag_nyu  
> logmag_conc_nyu logmag_frag_conc_nyu proximity_nyu prescandidate_nyu prox_prescandidate_nyu, robust;

Regression with robust standard errors                 Number of obs =      62
                                                       F( 10,    51) =   22.09
                                                       Prob > F      =  0.0000
                                                       R-squared     =  0.7478
                                                       Root MSE      =  1.0501

------------------------------------------------------------------------------
             |               Robust
legparties~u |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
fragmentat~n |  -.2248163   .1265585    -1.78   0.082    -.4788932    .0292605
concentrat~n |   .2562715   .3113018     0.82   0.414     -.368693     .881236
  logmag_nyu |   .2313167   .3456314     0.67   0.506    -.4625673    .9252008
frag_conc_~u |   .0667588   .0751343     0.89   0.378    -.0840795    .2175971
logmag~g_nyu |  -.0417166   .0576189    -0.72   0.472    -.1573914    .0739582
logmag_con~u |  -.4795553   .1891182    -2.54   0.014    -.8592259   -.0998847
logmag_fra.. |   .1191454   .0361963     3.29   0.002     .0464784    .1918125
proximity_~u |  -1.052137   .4961196    -2.12   0.039    -2.048138   -.0561352
prescandid~u |   1.063056    .387872     2.74   0.008     .2843704    1.841742
prox_presc~u |  -.2099409   .3445643    -0.61   0.545    -.9016826    .4818008
       _cons |   1.089721   .2999469     3.63   0.001     .4875519    1.691889
------------------------------------------------------------------------------

. *     ****************************************************************  *;
. *       Create x-axis for modifying variable (FRAGMENTATION) = JH       *;
. *     ****************************************************************  *;
. generate JH=((_n-1)/10);

.     replace JH=. if _n>100;
(0 real changes made)

. generate str1 txt="*";

. *     ****************************************************************  *;
. *       Grab elements of the matrix required for calculating            *;
. *       conditional coefficients and standard errors.                   *;
. *     ****************************************************************  *;
. matrix b=e(b);

. matrix V=e(V);

. scalar b1=b[1,1];

. scalar b2=b[1,2];

. scalar b3=b[1,3];

. scalar b4=b[1,4];

. scalar b5=b[1,5];

. scalar b6=b[1,6];

. scalar b7=b[1,7];

. scalar b8=b[1,8];

. scalar b9=b[1,9];

. scalar b10=b[1,10];

. scalar varb1=V[1,1];

. scalar varb2=V[2,2];

. scalar varb3=V[3,3];

. scalar varb4=V[4,4];

. scalar varb5=V[5,5];

. scalar varb6=V[6,6];

. scalar varb7=V[7,7];

. scalar varb8=V[8,8];

. scalar varb9=V[9,9];

. scalar varb10=V[10,10];

. scalar covb1b4=V[1,4];

. scalar covb1b5=V[1,5];

. scalar covb1b7=V[1,7];

. scalar covb3b4=V[3,4];

. scalar covb3b5=V[3,5];

. scalar covb3b6=V[3,6];

. scalar covb3b7=V[3,7];

. scalar covb4b5=V[4,5];

. scalar covb4b7=V[4,7];

. scalar covb5b6=V[5,6];

. scalar covb5b7=V[5,7];

. scalar covb6b7=V[6,7];

. set more off;

. scalar list b1 b2 b3 b4 b5 b6 b7 varb1 varb2 varb3 varb4 varb5 varb6 varb7 
>             covb1b4 covb1b5 covb1b7 covb4b5 covb4b7 covb5b7;
        b1 = -.22481632
        b2 =  .25627147
        b3 =  .23131673
        b4 =   .0667588
        b5 = -.04171663
        b6 = -.47955528
        b7 =  .11914543
     varb1 =  .01601706
     varb2 =  .09690883
     varb3 =   .1194611
     varb4 =  .00564516
     varb5 =  .00331994
     varb6 =  .03576569
     varb7 =  .00131017
   covb1b4 = -.00609377
   covb1b5 =  -.0044545
   covb1b7 =   .0018696
   covb4b5 =  .00074096
   covb4b7 = -.00166423
   covb5b7 =  -.0013198

. *     ****************************************************************  *;
. *         Create full range of conditional coefficients for logmag      *;
. *     ****************************************************************  *;
. gen conb0=b3+b5*JH+b6*0+b7*(0*JH) if _n<100;
(1 missing value generated)

. gen conb1=b3+b5*JH+b6*1+b7*(1*JH) if _n<100;
(1 missing value generated)

. gen conb2=b3+b5*JH+b6*2+b7*(2*JH) if _n<100;
(1 missing value generated)

. gen conb3=b3+b5*JH+b6*3+b7*(3*JH) if _n<100;
(1 missing value generated)

. gen conb4=b3+b5*JH+b6*4+b7*(4*JH) if _n<100;
(1 missing value generated)

. set more off;

. *     ****************************************************************  *;
. *           Create full range of conditional standard errors            *;
. *     ****************************************************************  *;
. gen conse0=sqrt(varb3
>                 + varb5*JH^2 + varb6*(0^2) + varb7*(JH^2)*(0^2)
>                 + 2*JH*covb3b5 + 2*0*covb3b6 + 2*0*JH*covb3b7 + 2*0*JH*covb5b6
>                 + 2*0*(JH^2)*covb5b7) + 2*(0^2)*JH*covb6b7  if _n<100;
(1 missing value generated)

.                 gen conse1=sqrt(varb3
>                 + varb5*JH^2 + varb6*(1^2) + varb7*(JH^2)*(1^2)
>                 + 2*JH*covb3b5 + 2*1*covb3b6 + 2*1*JH*covb3b7 + 2*1*JH*covb5b6
>                 + 2*1*(JH^2)*covb5b7) + 2*(1^2)*JH*covb6b7  if _n<100;
(1 missing value generated)

.                 gen conse2=sqrt(varb3
>                 + varb5*JH^2 + varb6*(2^2) + varb7*(JH^2)*(2^2)
>                 + 2*JH*covb3b5 + 2*2*covb3b6 + 2*2*JH*covb3b7 + 2*2*JH*covb5b6
>                 + 2*2*(JH^2)*covb5b7) + 2*(2^2)*JH*covb6b7  if _n<100;
(1 missing value generated)

.                 gen conse3=sqrt(varb3
>                 + varb5*JH^2 + varb6*(3^2) + varb7*(JH^2)*(3^2)
>                 + 2*JH*covb3b5 + 2*3*covb3b6 + 2*3*JH*covb3b7 + 2*3*JH*covb5b6
>                 + 2*3*(JH^2)*covb5b7) + 2*(3^2)*JH*covb6b7  if _n<100;
(1 missing value generated)

.                 gen conse4=sqrt(varb3
>                 + varb5*JH^2 + varb6*(4^2) + varb7*(JH^2)*(4^2)
>                 + 2*JH*covb3b5 + 2*4*covb3b6 + 2*4*JH*covb3b7 + 2*4*JH*covb5b6
>                 + 2*4*(JH^2)*covb5b7) + 2*(4^2)*JH*covb6b7  if _n<100;
(1 missing value generated)

.                                set more off;

. *     ****************************************************************  *;
. *                           Create t statistics                         *;
. *     ****************************************************************  *;
. gen t0=conb0/conse0;
(1 missing value generated)

. gen t1=conb1/conse1;
(1 missing value generated)

. gen t2=conb2/conse2;
(1 missing value generated)

. gen t3=conb3/conse3;
(1 missing value generated)

. gen t4=conb4/conse4;
(1 missing value generated)

. *     ****************************************************************  *;
. *       Generate a variable equal to conditional betas                  *;
. *     ****************************************************************  *;
. gen consb0=conb0;
(1 missing value generated)

. gen consb1=conb1;
(1 missing value generated)

. gen consb2=conb2;
(1 missing value generated)

. gen consb3=conb3;
(1 missing value generated)

. gen consb4=conb4;
(1 missing value generated)

. *     ****************************************************************  *;
. *       Replace consb_ = missing if t score not bigger than cutoff      *;
. *     ****************************************************************  *;
. replace consb0 = . if abs(t0)<2.01;
(99 real changes made, 99 to missing)

. replace consb1 = . if abs(t1)<2.01;
(99 real changes made, 99 to missing)

. replace consb2 = . if abs(t2)<2.01;
(64 real changes made, 64 to missing)

. replace consb3 = . if abs(t3)<2.01;
(41 real changes made, 41 to missing)

. replace consb4 = . if abs(t4)<2.01;
(25 real changes made, 25 to missing)

. set textsize 100;

. *     ****************************************************************  *;
. *       Graph the effect of logmag on legislative parties conditional on*;
. *       fragmentation                                                   *;
. *     ****************************************************************  *;
. graph twoway   line conb0 JH , clpattern(solid) clwidth(vthin)
>         ||  scatter consb0 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb1 JH , clpattern(solid) clwidth(vthin)
>         ||  scatter consb1 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb2 JH , clpattern(solid) clwidth(vthin)
>         ||  scatter consb2 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  line conb3 JH , clpattern(solid) clwidth(vthin)
>         ||  scatter consb3 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)        
>         ||  line conb4 JH , clpattern(solid) clwidth(vthin)
>         ||  scatter consb4 JH,  mlabel(txt) msymbol(i) mlabsize(vsmall) mlabgap(-1.0) mlabposition(11)
>         ||  ,   
>             ysize(6)
>             xsize(8)
>             title(Estimated Causal Effect of Logged Average District Magnitude, size(4) justification(center))
>             subtitle(" " "Dependent Variable: Effective Number of Legislative Parties" " " " ", size(3) justification
> (center))
>             xlabel(0 1 2 3 4 5 6 7 8 9 10, labsize(2.5)) 
>             ylabel(-2 -1 0 1 2 3 , labsize(2.5))
>             yscale(noline)
>             xscale(noline)
>             yline(0, lcolor(black)) yline(-2 -1  1 2 3 , lcolor(white)) 
>             xtitle(Fragmentation Index, size(3))
>             ytitle("Estimated Causal Effect of Logged Average" "District Magnitude", size(3))
>             xsca(titlegap(2))
>             ysca(titlegap(4.5))
>             text(2.7 11.40 "Concentration Index=4", justification(left) size(2.5))
>             text(1.95 11.40 "ConcentrationIndex=3", justification(left) size(2.5))
>             text(1.25 11.40 "Concentration Index=2", justification(left) size(2.5))
>             text(0.5 11.40 "Concentration Index=1", justification(left) size(2.5))
>             text(-0.12 11.40 "Concentrationn Index=0", justification(left) size(2.5))
>             text(3 2.7 "* indicates significance at the 95% level", justification(left) size(2.5))
>             legend(off)
>             scheme(s2mono) graphregion(fcolor(white))
>             graphregion(margin(r=28));

. *     ****************************************************************  *;
. *                               Save picture                            *;
. *     ****************************************************************  *;
. translate @Graph addresults\logmag1_leg.wmf, replace;
(note: file addresults\logmag1_leg.wmf not found)
(file Z:\interactionmodels\addresults\logmag1_leg.wmf written in Windows Metafile format)

. log close;
       log:  Z:\interactionmodels\addresults\legislativeparties_golder.log
  log type:  text
 closed on:  10 Jan 2007, 20:32:19
-----------------------------------------------------------------------------------------------------------------------
